package com.seur.configuracion;

import org.apache.log4j.PropertyConfigurator;

import javax.servlet.http.HttpServlet;

/**
 * User: Diego
 * Date: 02-jun-2009
 * Time: 8:06:53
 */
public class Log4jInit extends HttpServlet {

    public void init(){
        String file = getInitParameter("path-log-properties");
        if (file != null)
            PropertyConfigurator.configureAndWatch(file, 60000);
        else
            System.out.println("No se ha configurado el trazador porque no se ha encontrado el fichero " + getInitParameter("path-log-properties"));
    }
}
